package org.xxforest.game.core.scenes.scene2d.events.type;

import org.xxforest.game.core.scenes.scene2d.XXNode;
import org.xxforest.game.core.scenes.scene2d.events.XXEvent;
import org.xxforest.game.core.scenes.scene2d.events.XXEventType;

import com.badlogic.gdx.utils.Pools;

public class XXMouseMoveEvent implements XXEvent {
	
	private float x,y ;
	private XXNode node ;
	
	public static XXMouseMoveEvent create(){
		return Pools.obtain(XXMouseMoveEvent.class);
	}
	
	public XXMouseMoveEvent mouseMove(XXNode fromNode , float x ,float y){
		this.x = x ;
		this.y = y ;
		this.node = fromNode ;
		return this ;
	}

	@Override
	public void dispose() {
		Pools.free(this);
	}

	@Override
	public XXEventType getEventType() {
		return XXEventType.MOUSEMOVE;
	}

	public float getX() {
		return x;
	}

	public float getY() {
		return y;
	}

	public XXNode getNode() {
		return node;
	}

	
}
